package com.example.demo;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiOperation;



@RestController
@Api("swaggerDemoController相关的api")
public class TestController {
	/*	@SuppressWarnings("rawtypes")
	@RequestMapping("/test")
	public Object test(NodInfoSto p) {
		 
		  p.setSeqnr("zzzz");
		  p.setVbelv("nnnn");
//		  p.setTranLoadNo("PZ171103000033");
		  SlpsJsonResult o = apiClient.updateNodInfo(p);
		return o;
		
	}*/
	@GetMapping("/getUser")
	@ApiOperation(value = "根据id查询用户信息", notes = "查询数据库中某个的用户信息")
	@ApiImplicitParam(name = "id", value = "单个用户id", dataType = "int",required=true)
	public  User  getUser(Integer id){		
		User u =new User();
		u.setAddr("成都市武侯区");
		u.setName("tom");
		u.setId(1);
		return u;
		
	}
}
